const userName = { // 用户名验证规则
  required: true,
  user: true,
  minlength: 6,
  maxlength: 20,
  // checkUserExist: true // 用户名重复校验
}
// 设备号和激活码
const deviceCode = {
  required: true,
  numberOrCharacter: true,
  maxlength: 200
}

const checkPropertyName = { // 楼盘重复验证
  required: true,
  checkProperty: true
}

const checkPropertyTypeName = { // 楼盘户型重复验证
  required: true,
  checkPropertyType: true
}

const checkDeveloperName = { // 楼盘户型重复验证
  required: true,
  checkDeveloper: true
}

const companyName = { // 企业名称验证规则
  required: true,
  minlength: 5,
  maxlength: 20
}

const companyCode = { // 企业简码验证规则
  required: true,
  minlength: 2,
  maxlength: 20
}

const companyAlias = { // 企业简称验证规则
  required: true,
  minlength: 3,
  maxlength: 10
}

const contacts = { // 联系人
  required: true,
  hanzi: true,
  minlength: 1,
  maxlength: 8
}

const mobile = { // 联系手机
  required: true,
  phone: true
}

const moreMobile = { // 多个手机
  required: true,
  morePhone: true
}

const businessLicense = { // 营业执照
  minlength: 15,
  maxlength: 30
}

const settlement = { // 结算帐号
  minlength: 12,
  maxlength: 30
}

const remark = { // 备注
  maxlength: 400
}

/* 楼盘相关 */
const estateName = {
  required: true,
  minlength: 5,
  maxlength: 20
}

const address = {
  required: true,
  minlength: 5,
  maxlength: 50
}

const realName = {
  required: true,
  hanzi: true,
  minlength: 2,
  maxlength: 8
}

const servicePhone = {
  minlength: 11,
  maxlength: 20
}

const password = {
  required: true,
  pwd: true,
  minlength: 6,
  maxlength: 20
}

// 输入啥子或者英文
const numberOrCharacter = {
  required: true,
  numberOrCharacter: true,
  minlength: 6,
  maxlength: 20
}

const role = {
  required: true,
  minlength: 2,
  maxlength: 20
}

const code = {
  required: true,
  minlength: 5,
  maxlength: 20
}

// 户型相关
const housingTypeName = {
  required: true,
  minlength: 3,
  maxlength: 20
}

const area = {
  required: true,
  minlength: 1,
  maxlength: 10,
  number: true,
  min: 0
}

const structure = {
  required: true
}

const roomNo = {
  required: true,
  room: true
}

const price = {
  required: true,
  min: 0,
  max: 999999999999,
  number: true,
}

const pointPrice = {
  required: true,
  min: 0,
  max: 999999999999,
  number: true,
}

// 键盘编码
const keySn = {
  required: true,
  minlength: 3
}

// 商户号
const cusId = {
  required: true,
  numberOrCharacter: true
}

// 终端号
const identifier = {
  required: true,
  numberOrCharacter: true,
  checkTerminal: true
}

// url
const url = {
  url: true
}

// 卡号
const bank = {
  minlength: 16,
  maxlength: 19,
  number: true
}

// 上传图片
const checkImg = {
  checkImg: true
}

const checkBuildIn = {
  required: true,
  checkBuildInName: true
}

const checkBuildOut = {
  required: true,
  checkBuildOutName: true
}

const checkKeySn = {
  required: true,
  checkKeySnName: true,
  minlength: 3
}

const checkManagerNo = {
  // required: true,
  checkManagerNo: true,
  numberOrCharacter: true
}

export {
  userName,
  companyName,
  companyCode,
  companyAlias,
  contacts,
  mobile,
  moreMobile,
  businessLicense,
  settlement,
  remark,
  role,
  /* 楼盘相关 */
  estateName,
  address,
  realName,
  servicePhone,
  numberOrCharacter,
  password,
  code,
  housingTypeName,
  area,
  structure,
  roomNo,
  price,
  keySn,
  cusId,
  identifier,
  url,
  bank,
  checkPropertyName,
  checkDeveloperName,
  checkPropertyTypeName,
  checkImg,
  checkBuildIn,
  checkBuildOut,
  checkKeySn,
  deviceCode,
  checkManagerNo
}